var __extends =
    (this && this.__extends) ||
    (function () {
      var e = function (t, r) {
        return (e =
          Object.setPrototypeOf ||
          ({ __proto__: [] } instanceof Array &&
            function (e, t) {
              e.__proto__ = t;
            }) ||
          function (e, t) {
            for (var r in t)
              Object.prototype.hasOwnProperty.call(t, r) && (e[r] = t[r]);
          })(t, r);
      };
      return function (t, r) {
        function i() {
          this.constructor = t;
        }
        if ("function" != typeof r && null !== r)
          throw new TypeError(
            "Class extends value " + String(r) + " is not a constructor or null"
          );
        e(t, r),
          (t.prototype =
            null === r
              ? Object.create(r)
              : ((i.prototype = r.prototype), new i()));
      };
    })(),
  AXTreasureDetailDialog = (function (e) {
    function t() {
      return e.call(this) || this;
    }
    return (
      __extends(t, e),
      (t.showTreasureDialog = function (e) {
        null == this.treasureDetailView &&
          ((this.treasureDetailView = new t()),
          (this.treasureDetailView.zOrder = 1e3)),
          this.treasureDetailView.popup(!0),
          (this.treasureDetailView.treasureObj = e),
          (this.treasureDetailView.lable_treasureTitle.text = e.name),
          (this.treasureDetailView.lable_treasureDescr.text = e.descr),
          (this.treasureDetailView.label_treasure_price.text = e.price + "金"),
          this.treasureDetailView.button_treasure_buy.on(
            Laya.Event.CLICK,
            this.treasureDetailView,
            this.treasureDetailView.onTreasureBuysbtingDidClick
          );
      }),
      (t.prototype.onTreasureBuysbtingDidClick = function () {
        BuyMedicalView.showTreasure(this.treasureObj);
      }),
      (t.close = function () {
        this.treasureDetailView && this.treasureDetailView.close();
      }),
      t
    );
  })(ui.TabBarItemController.AXTreasureDetailDialogUI);
